home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Libris Britannia 4
/
science library(b).zip
/
science library(b)
/
PROGRAMM
/
CC_C
/
H515.ZIP
/
CENVID.ZIP
/
REBOOT_2.BAT
< prev
next >
Wrap
DOS Batch File
|
1993-10-19
|
1KB
|
31 lines
@echo off
REM ****************************************************************
REM *** Reboot_2.bat - Reboot computer by jumping to BIOS reboot ***
REM *** routine. This is an example of the CEnvi ***
REM *** asm() function. To provide protection ***
REM *** from accidentaly rebooting, you must ***
REM *** enter PLEASE as the first parameter. ***
REM ****************************************************************
REM **************************************************************
REM *** Check that "PLEASE" is the first parameter. CEnvi ***
REM *** return errorlevel if it is not please. ***
REM **************************************************************
CEnvi return( strcmpi("%1","Please") ? 1 : 0 )
if errorlevel 1 GOTO PLEASE
REM **************************************************************
REM *** A routine for rebooting is in the BIOS at location ***
REM *** FFFF:0000. To reboot, will use the CEnvi asm() ***
REM *** to execute the machine code: JMPF FFFF:0000, which in ***
REM *** machine code is the byte sequence EA 00 00 FF FF. ***
REM **************************************************************
CEnvi poke(0x472,0x1234,UWORD16); asm('\xEA\x00\x00\xFF\xFF');
:CENVI_EXIT
:PLEASE
ECHO Reboot_2.bat will reboot your computer. To execute Reboot.bat you
ECHO must enter: REBOOT_2 PLEASE